Skip to content

Add Tomcat web server plugin#1632

Open
JSCU-CNI wants to merge 1 commit intofox-it:mainfrom
JSCU-CNI:tomcat
Open

Add Tomcat web server plugin#1632
JSCU-CNI wants to merge 1 commit intofox-it:mainfrom
JSCU-CNI:tomcat

Conversation

@JSCU-CNI
Copy link
Contributor

This PR adds a generic plugin for Apache Tomcat.

Copy link
Contributor

@Paradoxis Paradoxis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice module, consider adding the two extra installation paths and other than that looks good to me

"/etc/tomcat*", # Handles symlinked conf folders (e.g. /var/lib/tomcat10/conf -> /etc/tomcat10)
"/usr/local/tomcat*",
"/opt/bitnami/tomcat*",
"/opt/tomcat*",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider adding:

  • /usr/share/tomcat*
  • /usr/share/tomcat*-root

https://askubuntu.com/questions/135824/what-is-the-tomcat-installation-directory

self.log_files = list(self.find_log_files())

def check_compatible(self) -> None:
if not self.installs and not self.configs and not self.log_files:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing docstring

Copy link
Member

@Schamper Schamper Mar 20, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's fine for this method.

from dissect.target.target import Target


def test_unix_logs_default_install(target_unix: Target, fs_unix: VirtualFilesystem) -> None:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't forget to add a test case for the other installation path from the previous comment

@codecov
Copy link

codecov bot commented Mar 20, 2026

Codecov Report

❌ Patch coverage is 86.47059% with 23 lines in your changes missing coverage. Please review.
✅ Project coverage is 81.09%. Comparing base (860456a) to head (6a26e68).
⚠️ Report is 5 commits behind head on main.

Files with missing lines Patch % Lines
dissect/target/plugins/apps/webserver/tomcat.py 86.79% 21 Missing ⚠️
dissect/target/plugins/apps/webserver/apache.py 66.66% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1632      +/-   ##
==========================================
- Coverage   81.11%   81.09%   -0.02%     
==========================================
  Files         402      403       +1     
  Lines       35244    35408     +164     
==========================================
+ Hits        28587    28713     +126     
- Misses       6657     6695      +38     
Flag Coverage Δ
unittests 81.09% <86.47%> (-0.02%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@codspeed-hq
Copy link

codspeed-hq bot commented Mar 20, 2026

Merging this PR will not alter performance

✅ 12 untouched benchmarks


Comparing JSCU-CNI:tomcat (6a26e68) with main (6117402)

Open in CodSpeed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants